import request from '@/utils/request'

// 查询房屋用途列表
export function listPurpose(query) {
  return request({
    url: '/house/purpose/list',
    method: 'get',
    params: query
  })
}

// 查询房屋用途详细
export function getPurpose(purposeId) {
  return request({
    url: '/house/purpose/' + purposeId,
    method: 'get'
  })
}

// 新增房屋用途
export function addPurpose(data) {
  return request({
    url: '/house/purpose',
    method: 'post',
    data: data
  })
}
// 修改房屋用途
export function updatePurpose(data) {
  return request({
    url: '/house/purpose',
    method: 'put',
    data: data
  })
}

